package cn.jtfadmin.activiti.domain.dto;

import cn.jtfadmin.base.lang.enums.BooleanEnum;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.Map;

/**
 * 流程实例
 * @author jtf
 * @since 0.0.2
 */
@Data
public class ProcessInstanceDTO implements Serializable {


    /**
     * 流程定义id
     */
    protected String processDefinitionId;

    /**
     * 流程定义名称
     */
    protected String processDefinitionName;

    /**
     * 流程定义 key
     */
    protected String processDefinitionKey;

    /**
     * 部署id
     */
    protected String deploymentId;

    /**
     * 业务key
     */
    protected String businessKey;

    /**
     * 挂起标志
     */
    protected BooleanEnum suspendedFlag;


    /**
     * 流程变量
     */
    protected Map<String, Object> processVaribles;


    /**
     * 租户id
     */
    protected String tenantId;


    /**
     * 流程名称
     */
    protected String name;

    /**
     * 流程描述
     */
    protected String description;

    /**
     *  localized name
     */
    protected String localizedName;

    /**
     * localized description
     */
    protected String localizedDescription;

    /**
     * 启动时间
     */
    protected Date startTime;

    /**
     * 开始用户id
     */
    protected String startUserId;

    /**
     * id
     */
    protected String id;

    /**
     * 是否已结束
     */
    protected BooleanEnum ended;



    public ProcessInstanceDTO() {
    }

    public ProcessInstanceDTO(String processDefinitionId, String processDefinitionName, String processDefinitionKey,
                              String deploymentId, String businessKey, BooleanEnum suspendedFlag, Map<String, Object> processVaribles,
                              String tenantId, String name, String description, String localizedName,
                              String localizedDescription, Date startTime, String startUserId, String id,
                              BooleanEnum ended) {
        this.processDefinitionId = processDefinitionId;
        this.processDefinitionName = processDefinitionName;
        this.processDefinitionKey = processDefinitionKey;
        this.deploymentId = deploymentId;
        this.businessKey = businessKey;
        this.suspendedFlag = suspendedFlag;
        this.processVaribles = processVaribles;
        this.tenantId = tenantId;
        this.name = name;
        this.description = description;
        this.localizedName = localizedName;
        this.localizedDescription = localizedDescription;
        this.startTime = startTime;
        this.startUserId = startUserId;
        this.id = id;
        this.ended = ended;
    }
}
